package com.heking.security;

import android.content.Context;

import org.junit.Test;
import org.junit.runner.RunWith;

import java.io.File;

import androidx.test.platform.app.InstrumentationRegistry;
import androidx.test.runner.AndroidJUnit4;

import static org.junit.Assert.assertEquals;

/**
 * Instrumented test, which will execute on an Android device.
 *
 * @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
 */
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
    private static final String TAG = ">>>ExampleInstrumentedTest";

    @Test
    public void useAppContext() {
        // Context of the app under test.
        Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
        assertEquals("com.heking.securitysdk.test", appContext.getPackageName());
        log("useAppContext");
    }

    @Test
    public void fileTest(){
        File externalRoot = FileManager.getExternalRoot();
        log("externalRoot:"+ externalRoot);


    }

    private void log(String msg){
        System.err.println(msg);
        LogUtils.e(TAG, msg);
    }

}